Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

auto release on vnext #5426

Merged
merged 9 commits into from
Jun 27, 2024
Merged

auto release on vnext #5426

merged 9 commits into from
Jun 27, 2024

Conversation

kanej
Copy link
Member

@kanej kanej commented Jun 24, 2024

Setup auto deployment of v-next packages.

Approach

  1. Rename v-next packages to be under the @ignored org in npm
  • @nomicfoundation/hardhat-core -> @ignored/hardhat-vnext-core
  • @nomicfoundation/hardhat-build-system -> @ignored/hardhat-vnext-build-system
  • @nomicfoundation/hardhat-errors -> @ignored/hardhat-vnext-errors
  • @nomicfoundation/hardhat-node-test-reporter -> @ignored/hardhat-vnext-node-test-reporter
  • @nomicfoundation/hardhat-utils -> @ignored/hardhat-vnext-utils
  • @nomicfoundation/hardhat-zod-utils -> @ignored/hardhat-vnext-zod-utils
  • @nomicfoundation/hardhat -> @ignored/hardhat-vnext
  1. Release version 2.0.0 for each of these packages manually
  2. Configure changeset to prerelease mode
  3. Setup VNEXT_NPM_TOKEN that is limited to the v-next packages
  4. Add new workflows for release v-next-changesets-release.yml leveraging the VNEXT_NPM_TOKEN
  5. Apply changeset for each v-next package that has a major update to 3.0.0-next.0 prerelease
  6. On merge into v-next this PR should publish pre-release versions of each v-next package under safe @ignored variants.

Copy link

vercel bot commented Jun 24, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
hardhat ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 27, 2024 9:07pm

Copy link

changeset-bot bot commented Jun 24, 2024

🦋 Changeset detected

Latest commit: 176f5c6

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 7 packages
Name Type
@ignored/hardhat-vnext-core Major
@ignored/hardhat-vnext Major
@ignored/hardhat-vnext-errors Major
@ignored/hardhat-vnext-node-test-reporter Major
@ignored/hardhat-vnext-utils Major
@ignored/hardhat-vnext-zod-utils Major
@ignored/hardhat-vnext-build-system Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

run: echo "//registry.npmjs.org/:_authToken=${{ secrets.VNEXT_NPM_TOKEN }}" > .npmrc
- name: Publish
if: needs.changesetcheck.outputs.CHANGESETS == 'found'
run: pnpm publish -r --no-git-checks --tag next --access public --dry-run
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apply dry run for now

if: needs.changesetcheck.outputs.CHANGESETS == 'found'
run: pnpm publish -r --no-git-checks --tag next --access public --dry-run
env:
NPM_CONFIG_PROVENANCE: true
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This gets us the provenance tag on npmjs.com

kanej added 3 commits June 27, 2024 20:30
In prep for auto-releasing from v-next, switch the v-next packages to be
named under the `@ignored` org.

Set the versions to `v2.0.0` in prep for manual release.
Taking the `@ignored` changes and applying them across imports and
things like the test commands.
Apply the prerelease config based on a flag of `next`.
kanej added 4 commits June 27, 2024 21:14
There are 3 moves here:

- Remove the pushing of tags
- Move the if check to the job level rather than per step
- temporarily comment out the git push
@kanej kanej force-pushed the chore/auto-release-on-vnext branch from a5a5a08 to 176f5c6 Compare June 27, 2024 21:05
@kanej kanej merged commit 667436a into v-next Jun 27, 2024
45 checks passed
@kanej kanej deleted the chore/auto-release-on-vnext branch June 27, 2024 21:09
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 27, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status:ready This issue is ready to be worked on
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants